const express = require('express');
const router = express.Router();
const UploadController = require('../controllers/UploadController');
const { authenticateToken } = require('../middleware/auth');

// 文件上传路由
router.post('/image', authenticateToken, UploadController.uploadImage);
router.post('/video', authenticateToken, UploadController.uploadVideo);
router.post('/audio', authenticateToken, UploadController.uploadAudio);
router.post('/document', authenticateToken, UploadController.uploadDocument);
router.post('/batch', authenticateToken, UploadController.batchUpload);
router.delete('/:type/:filename', authenticateToken, UploadController.deleteFile);
router.get('/:type/:filename', UploadController.getFileInfo);

module.exports = router; 